﻿using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using MooNet.Web.Api.Lib.Interfaces;
using MooNet.Web.Api.Lib.Models;

namespace MooNet.Api.ExampleConsumer.Controllers
{
    [HandleError]
    public class HomeController : Controller
    {
        private readonly IGigJunkieApiService m_service;
        public HomeController(IGigJunkieApiService gigJunkieApiService)
        {
            this.m_service = gigJunkieApiService;
        }

        public ActionResult Index()
        {
            EventsPagedModel eventsModel = m_service.GetEvents("london", null, null, null, null, null, null, null, null, null, null, null);
            ViewData["Events"] = eventsModel;

            return View();
        }

        public ActionResult About()
        {
            return View();
        }
    }
}
